package com.jerry.shop.converter;

import com.jerry.shop.bean.Product;
import com.jerry.shop.vo.ProductVo;

public class ProductConverter {

    public static ProductVo convert(Product product) {

        ProductVo productVo = new ProductVo();
        productVo.setProductId(product.getId());
        productVo.setProductName(product.getName());
        productVo.setProductPrice(product.getPrice());
        productVo.setProductDescription(product.getDescription());
        productVo.setProductIcon(product.getIcon());

        return productVo;
    }

}
